Method for preventing control packet looping and bridge apparatus using the method

ABSTRACT

A method for preventing a control packet loop in a network realizing node redundancy or circuit redundancy based on a rapid spanning tree protocol or a multiple spanning tree protocol is disclosed. The method includes the steps of: detecting a loop of a control packet of the rapid spanning tree protocol or the multiple spanning tree protocol; and discarding the control packet by which the loop is detected so as to prevent occurrence of the loop of the control packet.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to a control packet loop prevention methodand a bridge apparatus using the method. More particularly, the presentinvention relates to a control packet loop prevention method and abridge apparatus using the method in a network in which node redundancyor circuit redundancy is realized by using RSTP (Rapid Spanning TreeProtocol) or MSTP (Multiple Spanning Tree Protocol).

2. Description of the Related Art

The RSTP (Rapid Spanning Tree Protocol) that is standardized in IEEE802.1w/1y is a protocol for realizing node redundancy or circuitredundancy in a network using layer 2 switches.

The RSTP is known as a protocol for logically establishing a tee havingno loop by using parameters such as bridge priorities and the like thatare set in bridges (layer 2 switches). In RSTP, a topology of a networkcan be switched to a new topology within several seconds when a topologychange occurs due to parameter change or due to line failure or thelike.

FIG. 1A shows an example of a network configuration. In the network,bridges #1-#4 that are layer 2 switches are connected with each other.In the figure, a root bridge is a bridge having a strongest (smallest)bridge priority. A root bridge exists in a tree and the tree is formedcentering the root bridge. In the figure, the bridge 1 is the rootbridge. Each of the bridges #1-#4 has the priority value of the rootbridge.

Among the bridges #1-#4, a BPDU (Bridge Protocol Data Unit that iscontrol packet for RSTP) including items shown in FIG. 2 is sent andreceived so that each bridge is notified of a strength of each bridge orports of the bridge, parameters for STP for determining operationconditions of RSTP such as a hallo time. In addition, each bridge isnotified of an after-mentioned message age. Accordingly, information ofthe root bridge is transferred from the root bridge to each branch (endof tree).

As a port in a bridge, there are three types of ports: a designated port(shows as a black circle in figures), a root port (white circle) and analternate port (2 lines). The designated port is a port extending fromthe root bridge side to an end side of a tree. The root port isconnected to the designated port and receives a main signal and theBPDU. The alternate port is connected to the designated port, and thealternate port blocks the main signal but receives the BPDU.

The message age in the BPDU shown in FIG. 2 indicates a term of validityof the BPDU. Each time when the message age is transferred by a bridge,a larger value between 1 and an integer part of (max edges)/16 is addedto the message age. A BPDU having a message age equal to or larger thanthe max age is invalid so that the BPDU is discarded. A path cost is avalue used for weighting a route via which the BPDU is transferred. Eachtime when the BPDU is received, a value assigned to an input port isadded to the path cost. The smaller the path cost is, the more favorablethe route is. The hello time indicates a time interval at which the BPDUis transmitted. A default value of the hello time is 2 seconds.

In the RSTP, a tree that does not have any loop as shown in FIG. 1B isconstituted by exchanging strength information and the like ofbridge/port by using the BPDU among bridges. Then, as shown in FIG. 3A,when a failure occurs between bridges #1 and #3 or when a parameter ischanged, a new tree as shown in FIG. 3B is formed.

Japanese Laid Open Patent Application 11-168491 discloses a systemhaving a counter for counting a number of relay frames in which thecounter is cleared each time when a BPDU frame is receives, and when thevalue of the counter becomes larger than a predetermined value, it isjudged that a loop occurs so that frame relaying is stopped.

In a network in which four bridges #1-#4 are connected, assuming thatthe bridge priority of the bridge #1 that is the route bridge is changedfrom “4096” to “20480”. In this case, strength relationships to otherbridges #2-#4 are changed so that a topology change occurs. In thefigure, “RBID” indicates a root bridge ID in the BPDU, and MA indicatesa message age. The root bridge ID includes the bridge priority of theroot bridge and MAC address #1 of the root bridge.

In this case, the bridges #2 and #3 age out (discard) the bridgepriority (=4096) of the bridge #1 at the same time, and each bridgeupdates bridge priority of a root bridge by using a received BPDU, sothat a new RSTP tree shown in FIG. 5B is established after a few second.

However, as a matter of fact, the timing at which the aging out of thebridge priority of the bridge #1 is performed is different between thebridges #2 and #3. Thus, there is a possibility that a BPDU istransmitted among the bridges #2-#4 as if the bridge priority of thebridge #1 remains 4096.

That is, right after the bridge #2 ages out the information, the bridge#2 insists that the bridge #2 itself is the root bridge (2). However,since the bridge #3 has not aged out, the bridge #3 transmits the formerbridge priority=4096 of the bridge #1 to the bridge #2 (3). The bridge#2 transfers the bridge priority to a neighboring bridge (4).

Thus, the priority is transferred to the bridges #3, #2, #4 and then #3.At this time, as shown in FIG. 5A, if the bridge #3 ages out the bridgepriority of the root bridge, the bridge #3 further transfers the bridgepriority=4096, so that the priority is transferred to the bridges #2,#4, #3, #2 and #4 in this order. As a result, a loop is formed among thebridges #2, #3 and #4.

The looping BPDU continues to exist as long as the message age value inthe BPDU is equal to or smaller than the max age value. Thus, forexample, since a default max age is 20, the looping BPDU continues toexist while the BPDU is being transferred through 20 bridges at themaximum. That is, the looping BPDU exists for more than 10 seconds.

The above-mentioned explanation is based on a case where there is oneloop for the sake of simplicity. If there are a plurality of loops, theabove-mentioned operations are intertwined with each other, so thatthere is a possibility that it may take several minutes at the maximumuntil the looping BPDU disappears after a bridge priority change isperformed. For example, also in the case shown in FIGS. 4A-4B and 5A-4B,there is a possibility that a loop may occur in bridges #1, #2 and #3and in bridges #1, #2, #3 and #4. Thus, there is a problem in that ittakes a long time to switch a tree.

In this case, since a new RSTP tree is constructed after the BPDU havingthe bridge priority 4096 of the bridge #1 disappears, it may takeseveral minutes at the maximum to generate a new tree. Off course, themain signal is disconnected for the same time interval as the treereconstructing time.

This phenomenon may occur not only when the bridge priority is changedbut also when a node failure (failure of BPDU sending function and thelike) in the root bridge #1 occurs. In addition, this phenomenon mayoccur for MSTP defined in IEEE802.1s in the same way.

SUMMARY OF THE INVENTION

An object of the present invention is to provide a control packet loopprevention method and a bridge apparatus using the method for preventinga loop of the control packet so as to decrease the time for switching atree, decrease the disconnected time of the main signal and prevent aloop of the main signal.

The above-object is achieved by a method for preventing a control packetloop in a network realizing node redundancy or circuit redundancy basedon a rapid spanning tree protocol or a multiple spanning tree protocol,the method including the steps of:

detecting a loop of a control packet of the rapid spanning tree protocolor the multiple spanning tree protocol; and

discarding the control packet by which the loop is detected so as toprevent occurrence of the loop of the control packet.

The above-object is also achieved by a bridge apparatus for preventing acontrol packet loop in a network realizing node redundancy or circuitredundancy based on a rapid spanning tree protocol or a multiplespanning tree protocol, the method including the steps of:

a loop detection part for detecting a loop of a control packet of therapid spanning tree protocol or the multiple spanning tree protocol; and

a control loop discarding part for discarding the control packet bywhich the loop is detected.

The bridge apparatus may be connected to a root bridge, and the controlmessage is received after the bridge apparatus ages out information ofthe root bridge, wherein, the loop detection part detects the loop ofthe control packet on condition that a root bridge priority and a rootbridge address included in the control packet are the same as a priorityand an address of the root bridge and that a message age in the controlpacket is not 0.

In the bridge apparatus, when a priority of the bridge apparatus that isa root bridge is changed, the loop detection part detects the loop ofthe control packet on condition that a root bridge address included inthe control packet is the same as an address of the bridge apparatus andthat a root bridge priority included in the control packet is differentfrom the changed priority of the bridge apparatus.

In the bridge apparatus, the loop detection part may detect the loop byusing the control packet that is received within a predetermined timeperiod after aging out the information.

According to the present invention, occurrence of a loop of the controlpacket can be prevented so that the time for switching a tree and thedisconnecting time of the main signal can be decreased. In addition, aloop of the main signal can be prevented.

BRIEF DESCRIPTION OF THE DRAWINGS

Other objects, features and advantages of the present invention willbecome more apparent from the following detailed description when readin conjunction with the accompanying drawings, in which:

FIGS. 1A and 1B are figures for explaining a network configuration andgeneration of a tree by using RSTP;

FIG. 2 is a figure for explaining BPDU;

FIGS. 3A and 3B are figures for explaining a network configuration andgeneration of a tree by using RSTP in an event of a failure;

FIGS. 4A and 4B show change of network states when a topology changeoccurs in a conventional technology;

FIGS. 5A and 5B show change of network states when a topology changeoccurs in a conventional technology;

FIGS. 6A and 6B show change of network states when a topology changeoccurs according to the present invention;

FIG. 7 shows change of network states when a topology change occursaccording to the present invention;

FIG. 8 is a block diagram of an embodiment of a bridge apparatus of thepresent invention;

FIG. 9 is a functional block diagram of an embodiment of RSTP processesin a CPU;

FIG. 10 is a flowchart showing a filter process performed by a BPDU loopdetection/filter part 20 in a bridge connected to a former root bridgeaccording to a first embodiment;

FIG. 11 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the bridge connected to the former rootbridge according to a second embodiment;

FIG. 12 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the bridge connected to the former rootbridge according to a third embodiment;

FIG. 13 shows change of network states when a topology change occursaccording to the present invention;

FIG. 14 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the former root bridge according to afourth embodiment;

FIG. 15 shows change of network states when a topology change occursaccording to the present invention;

FIG. 16 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the former root bridge according to afifth embodiment;

FIG. 17 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the former root bridge according to asixth embodiment;

FIG. 18 is a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in the former root bridge according to aseventh embodiment.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

In the following, embodiments of the present invention are described.

In the present invention, a received BPDU that causes a BPDU loop isdetected. Then, the BPDU that may cause a loop is discarded to preventthe BPDU from being transferred to other bridge. Accordingly, any BPDUloop does not occur and reconstruction of a tree can be performed forseveral seconds.

More specifically, a bridge connected to a root bridge determines that aBPDU loop occurs if a root bridge ID (bridge priority of a root bridgeand the MAC address of a root bridge) in a BPDU received after aging outis the same as a root bridge ID before aging out and if the message ageis not 0. Then, the received BPDU is discarded.

Since a root bridge transmits a BPDU with message age=0, it can bedetermined that a root bridge other than a former root bridge (rootbridge before topology change) transfers the BPDU if the message age isnot 0.

In a network in which four bridges (layer 2 switches) #1-#4 areconnected as shown in FIG. 6A, it is assumed that a bridge priority ofthe bridge #1 that is a root bridge is changed from 4096 to 20480 sothat a topology change (tree reconstruction) occurs.

In the figure, RBID indicates a root bridge ID in a BPDU, and MAindicates a message age. The root bridge ID includes a bridge priority(4096 and the like) of a root bridge and a MAC address (#1 and the like)of the root bridge.

Right after the bridge #2 ages out, as shown in FIG. 6B, the bridge #2insists that the bridge #2 itself is a root bridge (2). However, sincethe bridge #3 has not aged out, the bridge #3 transmits the formerbridge priority 4096 of the bridge #1 to the bridge #2 (3).

In each bridge, if a bridge priority of a received BPDU is smaller thana bridge priority of a root bridge stored in the own bridge, the bridgeimmediately ages out the information. However, if the bridge priority ofa received BPDU is larger than a bridge priority of a root bridge storedin the own bridge, the bridge waits for a time three times larger thanthe hello time before aging out. In the meantime of the waiting, thebridge is waiting for receiving a BPDU having a smaller bridge prioritythat that stored in the own bridge as a bridge priority of a rootbridge. The timing for aging out is different among bridges due todifference of BPDU sending timing in each port in the root bridge anddue to error in timers in the bridges that detect aging out.

The bridge #2 that receives the BPDU transmitted in (3) determines thata BPDU loop occurs since it is not normal to receive the BPDU with theroot bridge ID=4096#1 and message age≠0 after aging out the former rootbridge priority. Then, the bridge #2 discards the BPDU.

Accordingly, it becomes possible to prevent a BPDU loop from continuingand enlarging. As a result, it becomes possible to construct a new treeby using STP parameters in each bridge for several seconds. That is, thestate changes from FIG. 6B to FIG. 7 in which the bridge #2 becomes aroot bridge.

FIG. 8 shows a block diagram of an embodiment of a bridge apparatus(layer 2 switch) of the present invention. In the figure, each of inputport circuits 12 ₁˜12 m receives a main signal including a BPDU. A BPDUextraction part 13 in each input port circuit extracts the BPDU from thereceived signal and provides the BPDU to the CPU 14, and provides themain signal to a switch part 16.

The CPU 14 receives a BPDU from each of the input port circuits 12 ₁˜12m so as to perform RSTP processing. A new BPDU generated in the CPU 14is provided to an output port circuit in output port circuits 18 ₁˜18 n.The switch part 16 receives the main signal from each of the input portcircuits 12 ₁˜12 m and performs switching processes. Switched mainsignals are provided to each of the output port circuits 18 ₁˜18 n. ABPDU inserting part 19 in each of the output port circuits 18 ₁˜18 ninserts the BPDU sent from the CPU 14 into the main signal sent from theswitch part 16, and outputs the main signal over the network.

FIG. 9 shows a functional block diagram of an embodiment of a RSTPprocess part in the CPU 14. In the figure, the BPDUs extracted by theinput port circuits 12 ₁˜12 m are provided to a BPDU loopdetection/filter part 20 and to an age out detection part 24 in a RSTPtree calculation part 22.

The BPDU loop detection/filter part 20 holds a root bridge ID beforeaging out. After the BPDU loop detection/filter part 20 is notified ofaging out from the age out detection part 24, the BPDU loopdetection/filter part 20 performs BPDU loop detection process bycomparing each root bridge ID in BPDUs provided from the input portcircuits 12 ₁˜12 m with the holding root bridge ID before aging out. Ifthe BPDU loop is detected, the received BPDU is discarded. A BPDU bywhich the BPDU loop is not detected is provided to a root bridgedetermining part 26 and to a BPDU generation part 28 in the RSTP treecalculation part 22. All BPDUs provided before aging out are sent to theroot bridge determination part 24 and to the BPDU generation part 28.

If the age out detection part 24 determines that a bridge priority ofthe received BPDU is smaller than a bridge priority of the root bridgeheld in the own bridge apparatus, the age out detection part 24immediately detects aging out. If the age out detection part 24determines that a bridge priority of the received BPDU is larger than abridge priority of the root bridge held in the own bridge apparatus, theage out detection part 24 waits for a time period three times longerthan the hello time. After that, the age out detection part 24 detectsaging out, and provides a result of the aging out detection to each ofthe BPDU loop detection/filter part 20 and the root bridge determinationpart 26.

When the root bridge determination part 26 is notified of aging out bythe age out detection part 24, the root bridge determination part 26performs update of the root bridge. In the update of root bridge, theroot bridge determination part 26 updates a current root bridge to a newroot bridge that is indicated by a root bridge ID of the BPDU providedfrom the BPDU loop detection/filter part 20. Then, the root bridgedetermination part 26 recalculates a RSTP tree on the basis of the newroot bridge. The root bridge determination part 26 sends a result of thecalculation to the BPDU generation part 28. The BPDU generation part 28generates a BPDU to be used for transmitting the calculation result toeach bridge that is connected to the own bridge, and provides the BPDUto each of the output port circuits 18 ₁˜18 n to which the bridges areconnected.

FIG. 10 shows a flowchart showing a filter process performed by the BPDUloop detection/filter part 20 in a bridge (for example, bridge #2, #3)connected to a former root bridge (bridge #1, for example) according toa first embodiment.

This procedure starts when the BPDU loop detection/filter part 20 isnotified of aging out from the age out detection part 24.

In the figure, the BPDU loop detection/filter part 20 receives a BPDUprovided from one of the input port circuits 12 ₁˜12 m in step S10.Then, in step S12, the BPDU loop detection/filter part 20 determineswhether a root bridge ID in the received BPDU is the same as a rootbridge ID before aging out that is held by the own bridge in step S12.

If they are the same, the BPDU loop detection/filter part 20 determineswhether the message age in the received BPDU is 0 in step S14. If themessage age is not 0 so that it can be determined that a bridge otherthan the former root bridge transferred the BPDU, the BPDU loopdetection/filter part 20 discards the BPDU since it is determined that aBPDU loop occurs in step S16.

On the other hand, if the root bridge IDs are different or if themessage age is 0, since the BPDU loop does not occur, the BPDU loopdetection/filter part 20 provides the BPDU to the root bridgedetermination part 26 in step S18.

After that, the BPDU loop detection/filter part 20 determines whether apredetermined time (several second to more than ten seconds, forexample) has elapsed after the BPDU loop detection/filter part 20 isnotified of aging out in step S20. If the predetermined time has notelapsed, the process goes to the step S10. When the predetermined timehas elapsed, this process ends. The reason for setting the predeterminedtime is that the BPDU loop occurs only within the predetermined timeright after the aging out occurs.

FIG. 11 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a bridge connected to theformer root bridge according to a second embodiment. The differencebetween FIGS. 10 and 11 is as follows. It is determined whether themessage age is 0 in step 14 in FIG. 10. On the other hand, it isdetermined whether a path cost is 0 in step S22 in FIG. 11. In FIG. 11,if the path cost is not 0, it is determined that the BPDU is transferredby a bridge other than the former root bridge so that it is determinedthat the BPDU loop occurs and the step goes to step S16. If the pathcost is 0, it is determined that BPDU loop does not occur and the stepgoes to step S18.

The path cost is always 0 in a BPDU output from a root bridge, and avalue is added to the path cost each time the BPDU is transferred by abridge. Therefore, it can be determined whether the BPDU has passedthrough a bridge other than a root bridge. That is, if the path cost isnot 0, it can be determined that the BPDU is one transferred from abridge other than the root bridge.

FIG. 12 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a bridge connected to theformer root bridge according to a third embodiment. The differencebetween FIGS. 10 and 12 is as follows. It is determined whether themessage age in the BPDU is 0 in step 14 in FIG. 10. On the other hand,in FIG. 12, it is determined whether the message age is a predeterminedvalue in step S24. If the message age is the predetermined value, it isdetermined that a bridge other than the former root bridge transferredthe BPDU in step S24, then, in step S16, it is determined that a BPDUloop occurs. If the message age is not the predetermined value, it isdetermined that the BPDU loop does not exist and the step moves to thestep S18.

In a network configuration shown in FIG. 6A, in a state of FIG. 6B, amessage age in a BPDU transferred from the bridge #3 is 2 in the bridge#2 connected to the former root bridge #1. On the other hand, as shownin FIG. 13, in a network configuration in which a bridge #5 is insertedbetween the bridges #2 and #3, a message age in a BPDU transferred fromthe bridge #5 is 4 in the bridge #2 connected to the former root bridge#1. That is, if the network configuration is known, the value of themessage age in a BPDU transferred from bridges other than the formerroot bridge #1 is predetermined. Therefore, if the message age in theBPDU is the predetermined value in step S24, it can be determined thatthe BPDU is one that is transferred from a bridge other than the formerroot bridge.

Like the message age, if the network configuration is known, the valueof the path cost in a BPDU transferred from bridges other than theformer root bridge #1 is predetermined. Therefore, it can be determinedwhether the path cost is a predetermined value in step S24 instead ofthe message age.

Further, in a network configuration shown in FIG. 6A, in the bridge #2connected to the former root bridge #1, an input port that receives aBPDU transferred from the bridge #3 is predetermined. Thus, the BPDUloop detection/filter part 20 may determine whether an input port thatreceives a BPDU is an input port that is connected to a bridge otherthan the former root bridge. If the input port is connected to a bridgeother than the former root bridge, the BPDU loop detection/filter part20 can determine that BPDU loop occurs. If the input port is connectedto the former root bridge, the BPDU loop detection/filter part 20 maydetermine that there is no BPDU loop and go to step S18.

Further, in step S14, for example, conditions may be combined in whichthe process goes to the step S18 if the message age is 0 and if the pathcost is 0.

FIG. 14 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a former root bridge(bridge #1, for example) according to a fourth embodiment. Thisprocedure is started when a bridge priority of the bridge apparatus ischanged.

In the figure, the BPDU loop detection/filter part 20 receives a BPDUprovided from an input port circuit in step S30. Then, the BPDU loopdetection/filter part 20 determines whether a MAC address in a rootbridge ID in the received BPDU is the same as a MAC address of the ownapparatus and determines whether a bridge priority in the root bridge IDis the same as the bridge priority of the own bridge.

If the MAC address in the root bridge ID in the received BPDU is thesame as the MAC address of the own apparatus and if the bridge priorityin the root bridge ID in the received BPDU is not the same as one of theown bridge, the BPDU loop detection/filter part 20 determines that aBPDU loop occurs and discards the BPDU.

In other cases, the BPDU loop detection/filter part 20 provides the BPDUto the root bridge determination part 26 in step S36 since the BPDU loopdoes not exist.

After that, it is determined whether a predetermined time (severalseconds to more than ten seconds) has elapsed after the bridge priorityof the own bridge is changed in step S38. If the predetermined time hasnot been elapsed, the process goes to step S30, and after thepredetermined time elapses, the process ends.

If a bridge that was a root bridge until the topology was changed isincluded, as shown in FIG. 15, right after the bridge #2 ages out, thebridge #2 insists that the own bridge is the root bridge. However, sincethe bridge #3 has not aged out, the bridge #3 transfers the formerbridge priority=4096 of the bridge #1 (3) to the bridge #2. Then, thebirdie #2 transfers the former bridge priority=4096 to the bridge #1(4). In the fourth embodiment shown in FIG. 14, the bridge #1 discardsthe BPDU transferred from the bridge #2 to prevent occurrence of a BPDUloop.

FIG. 16 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a former root bridge(bridge #1, for example) according to a fifth embodiment.

In the case shown in FIG. 14, the process goes to step S36 if thecondition of step S32 is satisfied. On the other hand, in thisembodiment, if the condition of step S32 is satisfied, the BPDU loopdetection/filter part 20 determines whether the message age in the BPDUis 0 in step S40. If the message age is not 0, the BPDU is provided tothe root bridge determination part 26 in step S36. According to thisembodiment, the BPDU loop can be detected more accurately.

FIG. 17 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a former root bridge(bridge #1, for example) according to a sixth embodiment.

As shown in FIG. 16, in the fifth embodiment, the BPDU loopdetection/filter part 20 determines whether the message age in the BPDUis 0. On the other hand, in this embodiment, as shown in FIG. 17, theBPDU loop detection/filter part 20 determines whether the path cost is 0in step S42. If the path cost is not 0, the BPDU loop detection/filterpart 20 determines that a BPDU loop is occurring since a bridge otherthan the former root bridge transfers the BPDU. If the path cost is 0,the process goes to step S36 since the BPDU loop does not exist.

FIG. 18 is a flowchart showing a procedure of a filter process performedby the BPDU loop detection/filter part 20 in a former root bridge(bridge #1, for example) according to a seventh embodiment.

As shown in FIG. 16, in the fifth embodiment, the BPDU loopdetection/filter part 20 determines whether the message age in the BPDUis 0. On the other hand, as shown in FIG. 18 in this embodiment, theBPDU loop detection/filter part 20 determines whether the message age isa predetermined value in step S44. If the message age is thepredetermined value, the BPDU loop detection/filter part 20 determinesthat a BPDU loop is occurring since a bridge other than the former rootbridge transfers the BPDU. If the message age is not the predeterminedvalue, the process goes to step S36 since the BPDU loop does not exist.

Like the case of the message age, since the path cost of the BPDU sentfrom a bridge other than the former root bridge #1 can be determinedaccording to the network configuration, the BPDU loop detection/filterpart 20 may determine whether the path cost is the predetermined valuein step S44.

Further, in step S44, the conditions can be combined in which theprocess goes to step S36 if the message age is 0 and if the path cost is0.

Although RSTP is taken an example in the above-mentioned embodiments,the present invention can be also applied to MSTP.

The present invention is not limited to the specifically disclosedembodiments, and variations and modifications may be made withoutdeparting from the scope of the present invention.

The present application contains subject matter related to Japanesepatent application No. 2004-203674, filed in the JPO on Jul. 9, 2004,the entire contents of which are incorporated herein by reference.

What is claimed is:
 1. A bridge apparatus comprising: a port configuredto transmit or receive packets; and a processor configured to detectpacket looping of a control packet, the packet looping being caused by atopology change that is caused by a change of a parameter, the parameterbeing indicative of bridge priority of one or more bridges in a network,the control packet being a control packet of a rapid spanning treeprotocol in a network which realizes node redundancy or circuitredundancy based on the rapid spanning tree protocol, and to discard, ona packet-by-packet basis, the control packet for which the packetlooping is detected so as to prevent the discarded control packet frombeing transferred through an output port while other control packets aretransferred through the output port, thereby preventing occurrence ofthe packet looping of the control packet, wherein, when a priority ofthe bridge apparatus that is a root bridge is changed, the processordetects the packet looping of the control packet on condition that aroot bridge address included in the control packet is the same as anaddress of the bridge apparatus and that a root bridge priority includedin the control packet is different from the changed priority of thebridge apparatus.
 2. A bridge apparatus, comprising: a port configuredto transmit or receive packets; and a processor configured to detectpacket looping of a control packet, the packet looping being caused by atopology change that is caused by a change of a parameter, the parameterbeing indicative of bridge priority of one or more bridges in a network,the control packet being a control packet of a multiple spanning treeprotocol in a network which realizes node redundancy or circuitredundancy based on the multiple spanning tree protocol, and to discard,on a packet-by-packet basis, the control packet for which the packetlooping is detected so as to prevent the discarded control packet frombeing transferred through an output port while other control packets aretransferred through the output port, thereby preventing occurrence ofthe packet looping of the control packet, wherein, when a priority ofthe bridge apparatus that is a root bridge is changed, the processordetects the packet looping of the control packet on condition that aroot bridge address included in the control packet is the same as anaddress of the bridge apparatus and that a root bridge priority includedin the control packet is different from the changed priority of thebridge apparatus.